package cn.org.xiaosheng.controller;

import cn.org.xiaosheng.context.InspectionSolverChooser;
import cn.org.xiaosheng.handle.InspectionSolver;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author XiaoSheng
 * @date 2025/3/17 下午9:15
 */
@RestController
public class TestController {

    @Autowired
    private InspectionSolverChooser chooser;

    @GetMapping("/test")
    public String test(int value) {
        InspectionSolver choose = chooser.choose(value);
        choose.solve(Long.valueOf(value), Long.valueOf(value));
        return "成功实现策略模式!";
    }


}
